package ooday04;

public class StaticDemo {
    public static void main(String[] args) {
        //
        StaticVar o1=new StaticVar();
        o1.show();
        StaticVar o2=new StaticVar();
        o2.show();
        StaticVar o3=new StaticVar();
        o3.show();
        System.out.println(StaticVar.b);
        System.out.println("------------------------------");
        //加载类时自动执行静态块
        StaticBlock o4=new StaticBlock();
        StaticBlock o5=new StaticBlock();
        System.out.println("------------------------------");
        StaticMethod.test();//静态方法通过类名点访问


    }
}
